MacGzip is Jean-loup Gailly's gzip compressor (GNU zip) for the Macintosh
Requires system 7; it should work in any Macintosh, but I haven't tested this version in any 68000 based model.
MacGzip can compress and decompress files; but as gzip is an UNIX compressor, if you gzip a Macintosh file, you will lose the resource fork (MacGzip will warn you before). Many text editors save things like font and size in the resource fork; custom icons are in the resource fork too; so for text and image files, you can discard the resource fork. If you want to retain all the information of any Mac file, you must use a MacBinary translator first.
You should read the files in 'GNU docs' folder…
• Configuring MacGzip
The easiest way to use MacGzip is as a Drag & Drop tool; depending on what you enter in the preferences dialog, the use can be fully automatic or manual.
- gzip standard options:
* gzip suffix: This is the '-s' option of standard gzip. Here you can specify an optional suffix to use instead of '.gz'. If you are using the standard suffixes, let it empty.
* Compression level: This is the '-[1-9]' option. The higher level, the slower and better compression. Compression level does not affect to decompression.
* Force overwrite: This is the '-f' option. If you set it, MacGzip will overwrite files or empty folders if their names are the same of an output file.
* -N: OK, this is not an option, in MacGzip its always on. (The original name and time stamp will be restored/saved)
- MacGzip options:
* Signatures:
Files compressed with gzip haven't any information about the kind of document of the original file; so to decompress them MacGzip has to guess it. Sometimes this can be done by looking at the suffix; when this fails, it will use these.
You can find more information about this in the 'Suffix Mapping' folder.
* ASCII compress:
This line tells to MacGzip when it has to convert newlines in the compression process. In the pop up menu you have 3 choices:
1) Only for TEXT files: Only files which are recognised as TEXT by the Macintosh will be compressed in ASCII mode. This is a safe setting unless you have binary files whose type is 'TEXT' (for example if you are using Versaterm FTP Server), if this is your case, you should get a file typer to fix your files.
2) Never: All files will be compressed in binary mode. This is the safest setting; if you aren't moving your compressed text files to a different operating system you'll never have problems with this.
3) Use 'gzip' menu: This is more flexible, especially if you are using the 'open' menu instead of the Drag & Drop mode; but also more dangerous.
You have an additional option: 'use startup key'. If you check it, you can force ASCII compression by holding 'opt-a' keys while dropping the files on MacGzip icon, overriding other settings.
* ASCII uncompress:
This line tells to MacGzip when it has to convert newlines in the decompression process. In the pop up menu you have 3 choices:
1) Use Fetch Prefs: MacGzip will look in Fetch preferences for the suffix of the decompressed name. If the suffix is found, the mode will be read from Fetch Prefs; otherwise binary mode will be used. Additionally, if the suffix is found, the creator and type of the expanded file will be correct, too.
2) Never: All files will be decompressed in binary mode. This is the safest setting; if you aren't moving your compressed text files to a different operating system you'll never have problems with this, and if you are getting compressed text files from the outside, you always can use a newline converter utility.
3) Use 'gzip' menu: This is more flexible, especially if you are using the 'open' menu instead of the Drag & Drop mode; but also more dangerous.
You have an additional option: 'use startup key'. If you check it, you can force ASCII decompression by holding '-a' key while dropping the files on MacGzip icon, overriding other settings.
-Remember: A binary file transmitted or compressed in ASCII mode is lost!
* Compress:
This line tells to MacGzip when it has to compress or expand files:
1) All non MacGzip Files: MacGzip will try to uncompress all files whose type does not match gzip, compress or zip; so if you have a compressed file without the correct type, MacGzip will try to compress it (you should get a better file transfer application...)
To determine if a file is compressed, MacGzip first check its type; if this does not match 'Gzip', 'ZIVU' or 'pZIP', the suffix is tested against ".gz", ".z", ".Z", ".taz", ".tgz", "-gz", "-z" and "_z".
2) Use 'gzip' menu: This is more flexible, especially if you are using the 'open' menu instead of the Drag & Drop mode.
You have an additional option: 'use startup key'. If you check it, you can force compression by holding 'opt' key while dropping the files on MacGzip icon, overriding other settings.
-Note: Startup keys should be hold down until the window appears.
• Using Macgzip
Select your files and drop them on MacGzip closed icon. (As MacGzip still uses the old method to open files; if you want to drop several files; you must quit MacGzip first; otherwise only the first one will be processed. I will fix this one of these years...)
The 'cancel' button (or cmd-period) raises a SIGINT and the program terminates (leaving the input file untouched and erasing the partial output file).
• About types & creators
I have used the following file Types:
suffix type creator
.gz Gzip Gzip gziped
.Z ZIVU Gzip compressed (from maccompress)
.z pZIP Gzip pkziped (from UnZip 2.0.1)
Anyway, read GNU’s gzip.doc to find out about formats.
When you download a file from a non-mac host, the program that you are using to download must assign it two flags: File Type and File Creator. These are two four character words that the Mac uses to know what icon they must have, what application must be opened when you make a double click on it, and if one SFGetFile (the 'open' dialog) should show the file or not.
So, you should use a downloading application with a "suffix mapping" menu or preference, or at least, a drag&drop file typer. You can find one, for example in
With this version of MacGzip, you don't need to use the correct type, but is a good idea to keep your files well typed.
If you want MacGzip to set the correct types but you don't use Fetch, you can find a 'Fetch Prefs' file in the 'Suffix Mapping'. You can copy it to your Preferences folder (in your System folder); and if you want to add suffixes, you can edit it with ResEdit or other resource editor (there is a template included).
• Warranty & so
The guarantee is directly proportional to the price of the application: NONE. (OK, if you loose a very important file with 2.3 Mb of data, let me know it and I will send you a few words of condolence).
• Thanks to:
Jean-loup Gailly ("jloup@chorus.fr") for gzip
Timothy Murphy ("tim@maths.tcd.ie" ) for Posix lib.
tree@uvm.edu for SpinCursors code
Greg Robbins for Prefs code
C.K. Haun (Apple DTS) for Movable Modal code
Bryan Stearns (Apple DTS) for Pop Up Menus code
Dave Rubinic for Easy Errors 1.0 resources
Lloyd Chambers (MacCompress) for Icons idea
David "ELEE74L" Alten ("elee74l@menudo.uh.edu") for icons improvement
And all other people whose source code I used ‘for documentation’